﻿using System;
using System.ComponentModel.DataAnnotations;
using System.Runtime.Serialization;


namespace Example.Base.Entities
{
    [DataContract(IsReference = true)]
    public class User : BaseEntity 
    {
        [DataMember]
        public string Login { get; set; }
        [DataMember]
        public string Password { get; set; }

        private bool _active = true;
        [DataMember]
        public bool Active 
        {
            get { return _active; }
            set { _active = value; }
        }

        private DateTime _lastVisit = DateTime.Now;
        [DataMember]
        public DateTime LastVisit 
        {
            get { return _lastVisit; }
            set { _lastVisit = value; }
        }

        private DateTime _registration = DateTime.Now;
        [DataMember]
        public DateTime Registration 
        {
            get { return _registration; }
            set { _registration = value; }
        }
    }
}
